package com.sheep.wenda.dao;

import com.sheep.wenda.persistence.WendaMapper;
import com.sheep.opt.AbstractDao;

/**
 * Created by IntelliJ IDEA.
 * User: wnj
 * Date: 2010-11-15
 * Time: 11:05:41
 * To change this template use File | Settings | File Templates.
 */
public class WendaDao2 extends AbstractDao {
    private WendaMapper mapper;

    public void getMapper() {
        mapper = session.getMapper(WendaMapper.class);
    }

    public int selectAll() {
        if (null != mapper) {
            try {
                return mapper.selectAll();
            } catch (Exception e) {
                e.printStackTrace();
            }
        }
        return -1;
    }
    public int selectAll2() {
        if (null != mapper) {
            try {
                return mapper.selectAll2();
            } catch (Exception e) {
                e.printStackTrace();
            }
        }
        return -1;
    }
}
